package com.origin.chaos.framework.bean.vo;

import com.origin.chaos.framework.core.AbstractPixelCanvas;
import com.origin.chaos.framework.core.PixelCanvas;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.hibernate.validator.constraints.Range;

import javax.validation.constraints.Min;
import javax.validation.constraints.NotBlank;

/**
 * @author: tao.ding
 * @date 2021-07-16
 */
@Data
public class CreateCanvasVo {

    @NotBlank(message = "画布名称必填")
    @ApiModelProperty(value = "画布名称", required = true)
    private String name;

    @Range(min = 10, max = AbstractPixelCanvas.MAX_SIZE, message = "画布宽可选返回[10, 1000]")
    @ApiModelProperty(value = "画布宽", required = true)
    private int width;

    @Range(min = 10, max = AbstractPixelCanvas.MAX_SIZE, message = "画布高可选返回[10, 1000]")
    @ApiModelProperty("画布高")
    private int height;

    @ApiModelProperty("两次绘画之间的间隔时间")
    private int paintIntervalTime;
}
